package com.zsrt.java.day20161223.zzm.demo05;

import java.util.Scanner;

import org.junit.Test;

public class SwitchTest {
	
	@Test
	public void switchText(){
		Scanner sc   = new Scanner(System.in);
		System.out.println("请输入您的成绩:");
	    String grade = sc.next();
	    sc.close();
	    
	    switch (grade) {
		case "A":System.out.println("优秀");   break;
		case "B":System.out.println("良好");   break;
		case "C":System.out.println("一般");   break;
		default: System.out.println("有问题");  break;
		}
	}
}
